<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
	pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Personal Page</title>
<link rel="stylesheet" type="text/css" href="PersonalPage.css" />
</head>
<%@page import="entities.*"%>
<%@page import="java.util.*"%>
<%
	RegisteredUser user = (RegisteredUser) request.getSession().getAttribute("user");
	List<Declares> abilities = (List<Declares>) request.getSession().getAttribute("userabilities");
%>
<body style="background-color: #94C0D6">
	<img alt="" src="Swim.jpg" style="height: 64px; width: 200px;">
	<form
		style="background-color: #A6B0DB; border-bottom-width: thin; border-right-width: thin; border-left-width: thin; border-top-width: thin; border-top-color: #8080FF; border-right-color: #8080FF; border-top-style: solid; border-right-style: solid; height: 24px;">
		<a href="SearchServlet">Back.</a> <a href="LogOutServlet">Logout.</a>
	</form>
<form style="width: 453px; background-color: #8080FF; height: 22px; vertical-align: middle; border-top-style: solid; border-top-color: #8080C0; border-right-color: #8080C0; border-right-width: thin; border-right-style: solid; border-top-width: thin">
			<center><b><%
				out.print(user.getSurname() + " " + user.getName() + " (alias "
						+ user.getUserId() + ")");
			%></b></center>
</form>
<br>
<br>
<br>
<fieldset style="width: 995px; background-color: #A6B0DB">
		<div class=field style="width: 276px;">
			<form style="height: 164px; width: 183px; background-color: #A6B0DB; border-top-style: solid; border-top-color: #8080FF; border-right-color: #8080FF; border-right-style: none; border-left-color: #8080FF; border-left-style: solid; border-left-width: thin; border-bottom-color: #8080FF; border-top-width: thin">

				<a href="UpdatePersonalInformation.jsp"><br> Edit Personal
					Info <br></a> 
					<a href="NotificationServlet">View Notifications <br> </a> 
					<a href="SuggestionsServlet">View Friend Suggestions <br></a> 
					<a href="PendingFriendshipServlet">View Friendship Requests <br></a>
				<a href="PendingHelpServlet">View Help Requests <br></a>
								<a href="RequestAbilityServlet">Request New Ability <br></a>
			</form>
		</div>
		<div class=field style="width: 276px;">
			<form class=form-inside
				style="width: 933px; height: 222px; list-style-type: disc">
				<fieldset style="width: 882px; background-color: #A6B0DB; border-bottom-style: none; border-top-style: none; border-left-style: none; border-right-style: none">
					<div class=field style="width: 276px; border-top-style: none; border-right-width: thin; border-right-style: none; border-top-width: thin">
						<table style="height: 83px; width: 256px; background-color: #8080C0; border-top-style: solid; border-top-color: #8080C0; border-right-color: #8080C0; border-right-width: thin; border-right-style: solid; border-top-width: thin">
							<tr>
								<td style="background-color: #8080FF">Personal Info</td>
							</tr>
							<tr>
								<td><b> E-mail:</b></td>
								<td>
									<%
										out.print(user.geteMail());
									%>
								</td>
							</tr>
							<tr>
								<td><b> Address:</b></td>
								<td>
									<%
										out.print(user.getAddress());
									%>
								</td>
							</tr>
							<tr>
								<td><b> Town:</b></td>
								<td>
									<%
										out.print(user.getCity());
									%>
								</td>
						</table>
					</div>
					<div class=field style="width: 262px;">
									<table style="height: 83px; width: 256px; background-color: #8080C0; border-top-style: solid; border-right-width: thin; border-right-style: solid; border-top-width: thin; border-top-color: #8080FF; border-right-color: #8080FF">
							<tr>
								<td style="background-color: #8080FF">Abilities</td>
								<td style="background-color: #8080FF">Rating</td>
								<td style="background-color: #8080FF">Feedback</td>
							</tr>
							<%
								for (Declares ability : abilities) {
									out.println("<tr> <td><b>"
											+ ability.getKey().getAbility().getName()
											+ "</b> </td>");
									out.println("<td><b>" + ability.getRating() + "</b> </td>");
									out.println("<td><b>" + ability.getNumberOfFeedbacks()
											+ "</b> </td></tr>");
								}
							%>
						</table>
					</div>
				</fieldset>
			</form>
		</div>
	</fieldset>



</body>

</html>